//
//  RotatingSquaresViewController.m
//  RotatingSquares
//
//  Created by User-09 on 3/26/14.
//  Copyright (c) 2014 IOTrainingCamp. All rights reserved.
//

#import "RotatingSquaresViewController.h"

@interface RotatingSquaresViewController ()
@property (strong, nonatomic) IBOutlet UIView *rotatingView;

@end

@implementation RotatingSquaresViewController

- (void)viewDidLoad
{
    [super viewDidLoad];
	// Do any additional setup after loading the view, typically from a nib.
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
-(void)viewDidAppear:(BOOL)animated{
    
}

-(void)rotate{
    CGAffineTransform transform = CGAffineTransformRotate(self.rotatingView.transform, (30));
    
    [UIView animateWithDuration:0.5 delay:0 options:UIViewAnimationOptionBeginFromCurrentState animations:^{
        self.rotatingView.transform = transform;
    }completion:nil];
}
@end
